<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>index</title>
    <link rel="stylesheet" href="/css/layui.css">
    <style>
        .layui-table th{
            text-align: center;
        }
    </style>
</head>
<body>
<div class="layui-container">
    <!--工具显示-->
    <div class="layui-row">
        <div class="layui-col-md3">
            <label class="layui-form-label">地区名称:</label>
            <div class="layui-input-block">
                <input type="text" name="netherlands" required  lay-verify="required" placeholder="请输入关键字" autocomplete="off" class="layui-input">
            </div>
        </div>
        <div class="layui-col-md4">
            <div class="layui-inline layui-input-block"> <!-- 注意：这一层元素并不是必须的 -->
                <input type="text" class="layui-input" id="test1" placeholder="请输入日期" name="date">
            </div>
        </div>
        <div class="layui-col-md2 center-block">
            <button type="button" class="layui-btn">查询</button>
        </div>
        <div class="layui-col-md2">
            <button type="button" class="layui-btn" id="btn-add">新增</button>
        </div>
    </form>

    <!--数据地方-->
    <div class="layui-row">
        <!--数据展示-->
        <table class="layui-table" lay-data="{width: 1100, height:300,
        url:'getAll', page:true, id:'tableList',limit:5,cellMinWidth: 50}" lay-filter="demo">
            <thead>
            <tr style="text-align: center">
                <th colspan="7">图书借阅系统</th>
            </tr>
            <tr>
                <!--layui怎么隐藏，怎么显示-->
                <th lay-data="{field:'id'}">主键Id</th>
                <th lay-data="{field:'netherlands'}">地区</th>
                <th lay-data="{field:'num'}">感染人数</th>
                <th lay-data="{field:'currd'}">时间</th>
                <th lay-data="{field:'lurn'}">录入人</th>
                <th lay-data="{field:'isborrowed',toolbar:'#barDemo',width:250}">操作</th>
            </tr>
            </thead>
            <!--, templet:changeBookType   ,hide:true-->
        </table>
    </div>
</div>

<script type="text/html" id="barDemo">
    <a class="layui-btn layui-btn-primary layui-btn-xs" lay-event="del">删除</a>
    <a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="upd">修改</a>
</script>
<script src="../layui.js" charset="utf-8"></script>
<script src="/js/jquery.min.js"></script>
<script src="/js/myjs/main.js"></script>
<script>
    layui.use('laydate', function(){
        var laydate = layui.laydate;

        //执行一个laydate实例
        laydate.render({
            elem: '#test1' //指定元素
        });
    });
</script>
</body>
</html>